# Maintainer: Antonio Rojas <arojas@archlinux.org>
# Contributor: Ashwin Vishnu <ashwinvis+arch at pr0t0nm4il dot com>
# Contributor: xantares

pkgname=python-pythran
pkgver=0.13.1
pkgrel=2
pkgdesc='Ahead of Time compiler for numeric kernels'
arch=(any)
url='https://pythran.readthedocs.io/'
license=(BSD)
depends=(python-ply python-numpy python-beniget xsimd boost)
makedepends=(python-setuptools python-pytest-runner)
source=(https://files.pythonhosted.org/packages/source/p/pythran/pythran-$pkgver.tar.gz)
sha256sums=('8aad08162f010e5425a7b254dd68d83311b430bb29f9252dce2eff3ba39497dd')

build() {
  cd pythran-$pkgver
  python setup.py build
}

package() {
  cd pythran-$pkgver
  python setup.py install --root="$pkgdir" --optimize=1 --skip-build
# python-scipy need these files to build, please dont remove them.
#rm -r "$pkgdir"/usr/lib/python*/site-packages/pythran/{boost,xsimd} # Remove bundled boost and xsimd
  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
}
